package com.example.wanjialei.pojo;

import java.util.ArrayList;
import java.util.List;

public class ProductExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public ProductExample() {
        oredCriteria = new ArrayList<>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andPnoIsNull() {
            addCriterion("pno is null");
            return (Criteria) this;
        }

        public Criteria andPnoIsNotNull() {
            addCriterion("pno is not null");
            return (Criteria) this;
        }

        public Criteria andPnoEqualTo(Integer value) {
            addCriterion("pno =", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoNotEqualTo(Integer value) {
            addCriterion("pno <>", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoGreaterThan(Integer value) {
            addCriterion("pno >", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoGreaterThanOrEqualTo(Integer value) {
            addCriterion("pno >=", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoLessThan(Integer value) {
            addCriterion("pno <", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoLessThanOrEqualTo(Integer value) {
            addCriterion("pno <=", value, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoIn(List<Integer> values) {
            addCriterion("pno in", values, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoNotIn(List<Integer> values) {
            addCriterion("pno not in", values, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoBetween(Integer value1, Integer value2) {
            addCriterion("pno between", value1, value2, "pno");
            return (Criteria) this;
        }

        public Criteria andPnoNotBetween(Integer value1, Integer value2) {
            addCriterion("pno not between", value1, value2, "pno");
            return (Criteria) this;
        }

        public Criteria andPmodelIsNull() {
            addCriterion("pmodel is null");
            return (Criteria) this;
        }

        public Criteria andPmodelIsNotNull() {
            addCriterion("pmodel is not null");
            return (Criteria) this;
        }

        public Criteria andPmodelEqualTo(String value) {
            addCriterion("pmodel =", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelNotEqualTo(String value) {
            addCriterion("pmodel <>", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelGreaterThan(String value) {
            addCriterion("pmodel >", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelGreaterThanOrEqualTo(String value) {
            addCriterion("pmodel >=", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelLessThan(String value) {
            addCriterion("pmodel <", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelLessThanOrEqualTo(String value) {
            addCriterion("pmodel <=", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelLike(String value) {
            addCriterion("pmodel like", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelNotLike(String value) {
            addCriterion("pmodel not like", value, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelIn(List<String> values) {
            addCriterion("pmodel in", values, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelNotIn(List<String> values) {
            addCriterion("pmodel not in", values, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelBetween(String value1, String value2) {
            addCriterion("pmodel between", value1, value2, "pmodel");
            return (Criteria) this;
        }

        public Criteria andPmodelNotBetween(String value1, String value2) {
            addCriterion("pmodel not between", value1, value2, "pmodel");
            return (Criteria) this;
        }

        public Criteria andCategoryIsNull() {
            addCriterion("category is null");
            return (Criteria) this;
        }

        public Criteria andCategoryIsNotNull() {
            addCriterion("category is not null");
            return (Criteria) this;
        }

        public Criteria andCategoryEqualTo(String value) {
            addCriterion("category =", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryNotEqualTo(String value) {
            addCriterion("category <>", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryGreaterThan(String value) {
            addCriterion("category >", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryGreaterThanOrEqualTo(String value) {
            addCriterion("category >=", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryLessThan(String value) {
            addCriterion("category <", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryLessThanOrEqualTo(String value) {
            addCriterion("category <=", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryLike(String value) {
            addCriterion("category like", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryNotLike(String value) {
            addCriterion("category not like", value, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryIn(List<String> values) {
            addCriterion("category in", values, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryNotIn(List<String> values) {
            addCriterion("category not in", values, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryBetween(String value1, String value2) {
            addCriterion("category between", value1, value2, "category");
            return (Criteria) this;
        }

        public Criteria andCategoryNotBetween(String value1, String value2) {
            addCriterion("category not between", value1, value2, "category");
            return (Criteria) this;
        }

        public Criteria andInventoryIsNull() {
            addCriterion("inventory is null");
            return (Criteria) this;
        }

        public Criteria andInventoryIsNotNull() {
            addCriterion("inventory is not null");
            return (Criteria) this;
        }

        public Criteria andInventoryEqualTo(Integer value) {
            addCriterion("inventory =", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryNotEqualTo(Integer value) {
            addCriterion("inventory <>", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryGreaterThan(Integer value) {
            addCriterion("inventory >", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryGreaterThanOrEqualTo(Integer value) {
            addCriterion("inventory >=", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryLessThan(Integer value) {
            addCriterion("inventory <", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryLessThanOrEqualTo(Integer value) {
            addCriterion("inventory <=", value, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryIn(List<Integer> values) {
            addCriterion("inventory in", values, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryNotIn(List<Integer> values) {
            addCriterion("inventory not in", values, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryBetween(Integer value1, Integer value2) {
            addCriterion("inventory between", value1, value2, "inventory");
            return (Criteria) this;
        }

        public Criteria andInventoryNotBetween(Integer value1, Integer value2) {
            addCriterion("inventory not between", value1, value2, "inventory");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeIsNull() {
            addCriterion("sale_volume is null");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeIsNotNull() {
            addCriterion("sale_volume is not null");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeEqualTo(Integer value) {
            addCriterion("sale_volume =", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeNotEqualTo(Integer value) {
            addCriterion("sale_volume <>", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeGreaterThan(Integer value) {
            addCriterion("sale_volume >", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeGreaterThanOrEqualTo(Integer value) {
            addCriterion("sale_volume >=", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeLessThan(Integer value) {
            addCriterion("sale_volume <", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeLessThanOrEqualTo(Integer value) {
            addCriterion("sale_volume <=", value, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeIn(List<Integer> values) {
            addCriterion("sale_volume in", values, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeNotIn(List<Integer> values) {
            addCriterion("sale_volume not in", values, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeBetween(Integer value1, Integer value2) {
            addCriterion("sale_volume between", value1, value2, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleVolumeNotBetween(Integer value1, Integer value2) {
            addCriterion("sale_volume not between", value1, value2, "saleVolume");
            return (Criteria) this;
        }

        public Criteria andSaleIsNull() {
            addCriterion("sale is null");
            return (Criteria) this;
        }

        public Criteria andSaleIsNotNull() {
            addCriterion("sale is not null");
            return (Criteria) this;
        }

        public Criteria andSaleEqualTo(Integer value) {
            addCriterion("sale =", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleNotEqualTo(Integer value) {
            addCriterion("sale <>", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleGreaterThan(Integer value) {
            addCriterion("sale >", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleGreaterThanOrEqualTo(Integer value) {
            addCriterion("sale >=", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleLessThan(Integer value) {
            addCriterion("sale <", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleLessThanOrEqualTo(Integer value) {
            addCriterion("sale <=", value, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleIn(List<Integer> values) {
            addCriterion("sale in", values, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleNotIn(List<Integer> values) {
            addCriterion("sale not in", values, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleBetween(Integer value1, Integer value2) {
            addCriterion("sale between", value1, value2, "sale");
            return (Criteria) this;
        }

        public Criteria andSaleNotBetween(Integer value1, Integer value2) {
            addCriterion("sale not between", value1, value2, "sale");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseIsNull() {
            addCriterion("out_warehouse is null");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseIsNotNull() {
            addCriterion("out_warehouse is not null");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseEqualTo(String value) {
            addCriterion("out_warehouse =", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseNotEqualTo(String value) {
            addCriterion("out_warehouse <>", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseGreaterThan(String value) {
            addCriterion("out_warehouse >", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseGreaterThanOrEqualTo(String value) {
            addCriterion("out_warehouse >=", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseLessThan(String value) {
            addCriterion("out_warehouse <", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseLessThanOrEqualTo(String value) {
            addCriterion("out_warehouse <=", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseLike(String value) {
            addCriterion("out_warehouse like", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseNotLike(String value) {
            addCriterion("out_warehouse not like", value, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseIn(List<String> values) {
            addCriterion("out_warehouse in", values, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseNotIn(List<String> values) {
            addCriterion("out_warehouse not in", values, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseBetween(String value1, String value2) {
            addCriterion("out_warehouse between", value1, value2, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andOutWarehouseNotBetween(String value1, String value2) {
            addCriterion("out_warehouse not between", value1, value2, "outWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseIsNull() {
            addCriterion("in_warehouse is null");
            return (Criteria) this;
        }

        public Criteria andInWarehouseIsNotNull() {
            addCriterion("in_warehouse is not null");
            return (Criteria) this;
        }

        public Criteria andInWarehouseEqualTo(String value) {
            addCriterion("in_warehouse =", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseNotEqualTo(String value) {
            addCriterion("in_warehouse <>", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseGreaterThan(String value) {
            addCriterion("in_warehouse >", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseGreaterThanOrEqualTo(String value) {
            addCriterion("in_warehouse >=", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseLessThan(String value) {
            addCriterion("in_warehouse <", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseLessThanOrEqualTo(String value) {
            addCriterion("in_warehouse <=", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseLike(String value) {
            addCriterion("in_warehouse like", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseNotLike(String value) {
            addCriterion("in_warehouse not like", value, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseIn(List<String> values) {
            addCriterion("in_warehouse in", values, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseNotIn(List<String> values) {
            addCriterion("in_warehouse not in", values, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseBetween(String value1, String value2) {
            addCriterion("in_warehouse between", value1, value2, "inWarehouse");
            return (Criteria) this;
        }

        public Criteria andInWarehouseNotBetween(String value1, String value2) {
            addCriterion("in_warehouse not between", value1, value2, "inWarehouse");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}